//
//  ZPZNetRequest+RecentProductsList.m
//  项目二网络请求
//
//  Created by 张峥 on 16/7/23.
//  Copyright © 2016年 张峥. All rights reserved.
//

#import "ZPZNetRequest+RecentProductsList.h"

@implementation ZPZNetRequest (RecentProductsList)
+ (void)getRecentProductsListTotalNum:(NSString *)totalNum comletion:(ZLReqComletion)comletion{
    NSMutableDictionary *numDic = [[NSMutableDictionary alloc]init];
    if (totalNum != nil) {
        [numDic setObject:totalNum forKey:@"totalNum"];
    }
    NSDictionary *resultDic = [NSDictionary dictionaryWithDictionary:[self getParametersPaeames:numDic]];
    [self sendRequestByParameters:resultDic Method:@"appIndex/getRecentProductsList" requestType:ZLApRequestPost Comletion:comletion];
}

+ (void)getRecentProductDetailId:(NSString *)Id comletion:(ZLReqComletion)comletion{
    NSMutableDictionary *numDic = [[NSMutableDictionary alloc]init];
    if (Id != nil) {
        [numDic setObject:Id forKey:@"id"];
    }
    NSDictionary *resultDic = [NSDictionary dictionaryWithDictionary:[self getParametersPaeames:numDic]];
    [self sendRequestByParameters:resultDic Method:@"appIndex/getRecentProductDetail" requestType:ZLApRequestPost Comletion:comletion];
    
}

+ (void)getRecentNewsListPageNum:(NSString *)pageNum pageSize:(NSString *)pageSize comletion:(ZLReqComletion)comletion{
    NSMutableDictionary *numDic = [[NSMutableDictionary alloc]init];
    if (pageNum != nil && pageSize != nil) {
        [numDic setObject:pageNum forKey:@"pageNum"];
        [numDic setObject:pageSize forKey:@"pageSize"];
    }
    NSDictionary *resultDic = [NSDictionary dictionaryWithDictionary:[self getParametersPaeames:numDic]];
    [self sendRequestByParameters:resultDic Method:@"appIndex/getRecentNewsList" requestType:ZLApRequestPost Comletion:comletion];
    
}

+ (void)getRecentNewsDetailTotalId:(NSString *)Id comletion:(ZLReqComletion)comletion{
    NSMutableDictionary *numDic = [[NSMutableDictionary alloc]init];
    if (![LStringUtils isTextEmpty:Id]) {
        [numDic setObject:Id forKey:@"id"];
    }
    NSDictionary *resultDic = [NSDictionary dictionaryWithDictionary:[self getParametersPaeames:numDic]];
    [self sendRequestByParameters:resultDic Method:@"appIndex/getRecentNewsDetail" requestType:ZLApRequestPost Comletion:comletion];
    
}


@end
